package org.huzhp.listener;

import org.springframework.stereotype.Service;

/**
 * @Description: 注册服务
 * @Author: huzp
 * @CreateDate: 2020/3/14 11:35
 * @Version: 1.0;
 */
@Service
public class RegisterService {

//    @Autowired
//    private IConsoleService consoleService;


//    public void register(String appName) {
//        GatewayRouteVo route = new GatewayRouteVo();
//        String name = appName.toLowerCase();
//        route.setRouteId(name);
//        route.setRouteUri("lb://"+name);
//        try {
//            RouteUtil.buildServiceCommon(route);
//            consoleService.saveRoute(route);
//        } catch (JsonProcessingException e) {
//
//        }
//    }
//
//    public void cancel(String appName) {
//        consoleService.deleteRoute(appName.toLowerCase());
//    }
}
